package cn.kgc.ffzw.day21;

import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;

public class Collection {
    public static void main(String[] args) {
        List list=new ArrayList();

        for (int i = 0; i < 10; i++) {
            list.add(i);
        }
        list.remove(1);
        list.set(0,"sda");
        list.get(0);
        System.out.println(list);

        List linkedList=new LinkedList();
        for (int i = 0; i < 10; i++) {
            linkedList.add(i);
        }
        linkedList.remove(2);
        linkedList.set(3,"sdsa");
        linkedList.get(8);
        System.out.println(linkedList);
        ((LinkedList) linkedList).element();
        System.out.println(linkedList);
    }
}
